package selectionweb.web.controller;

import lombok.extern.slf4j.Slf4j;
import org.springframework.context.annotation.Configuration;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.validation.Errors;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.ModelAttribute;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.config.annotation.ViewControllerRegistry;
import selectionweb.web.Ingredient;
import selectionweb.web.Ingredient.Type;
import selectionweb.web.Student;
import selectionweb.web.Course;

import javax.validation.Valid;
import java.util.Arrays;
import java.util.List;
import java.util.stream.Collectors;

@Slf4j
@Controller
@Configuration
@RequestMapping("/selectionResult")
public class SelectionResultController {
    @GetMapping
    public String personalController(Model model) {
        model.addAttribute("selectionResult", new Student());
        return "selectionResult";
    }
}

